#include <stdio.h>
#include <sys/types.h>
#include <string.h>
int main()
{
	FILE *fp;
	fp=fopen ("b","r+");
	char ch;
        char st[1000];
	int i=1,j=1,n=0;
        while ( (ch=fgetc(fp))!=EOF){
		//if(ch!='\n')st[i]=ch;
		//else st[i]='\\n';
		st[i]=ch;
		i++;
	}
	n=i;
        for(i=1;i<=n;i++)
	{
		if(st[i]=='\n')printf("  \\n");
		else printf("%3c",st[i]);
		if(i%16==0){
			printf("\n");
			for(;j<=i;j++)printf("%3x",st[j]);
			printf("\n");
			}
	}
        for(;j<=i-2;j++)printf("%-3x",st[j]);
        printf("\n");
	fclose(fp);
	return 0;
}
